package com.appbee.gdata.youtube.client.model;

import com.google.gwt.core.client.JavaScriptObject;
import com.google.gwt.core.client.JsArray;

public class SimpleEntry extends JavaScriptObject
{
	protected SimpleEntry(){}
	public final static native SimpleEntry create2(String id,String title,String content)/*-{return {id: id,title: title,content: content};}-*/;
	
	public final static native SimpleEntry create()/*-{return {title:'',id:'',content:'',defaultMedia:''};}-*/;
	public final native String getId() /*-{return this.id;}-*/;
	public final native void setId(String i) /*-{this.id = i;}-*/;
	public final native String getTitle() /*-{ return this.title; }-*/;
	public final native void setTitle(String t) /*-{ this.title=t; }-*/;
	public final native String getContent() /*-{ return this.content; }-*/;
	public final native void setContent(String content) /*-{ this.content=content; }-*/;
	public final native String getThumbnail() /*-{ return this.thumbnail; }-*/;
	public final native void setThumbnail(String thumbnail) /*-{ this.thumbnail=thumbnail; }-*/;
	public final native int getDuration() /*-{ if(this.duration){return this.duration;}else{return 0;} }-*/;
	public final native void setDuration(int duration) /*-{ this.duration=duration; }-*/;
	
	
	
	public static native JsArray<SimpleEntry> parseJson(String jsonStr) /*-{
	  var v = eval(jsonStr);
	  return v;
	}-*/;	
}
